const baseUrl="http://localhost:7001/api";
export function request(config){
	return new Promise((re,rj)=>{
		wx.request({
		  url: baseUrl+config.url,
		  data: config.data,
		  method: config.method || "GET",
		  header: config.headers||{'content-type': 'application/x-www-form-urlencoded'},
		  success:(res)=>{re(res)},
		  fail:(err)=>{rj(err)}
		})
	})
}